package com.aidong.login.dao;

import java.util.Map;

import org.apache.ibatis.annotations.Param;

import com.aidong.login.entity.Member;
import com.aidong.login.entity.MemberBase;

/**
 * 手机号码登录接口
 * 
 * @author java
 * @version 1.0 2015.07.03
 */
public interface MemberLoginDao {

	/**
	 * 手机号码登录
	 * 
	 * @param phoneNo
	 * @return
	 */
	public Map<String, Object> getPhoneToLogin(String phoneNo);

	/**
	 * 无密码快捷登陆
	 * 
	 * @param phoneNo
	 * @return
	 */
	public Map<String, Object> getNotPasswordLogin(String phoneNo);

	/**
	 * 无密码快捷注册
	 * 
	 * @param map
	 * @return
	 */
	public int addNotPassRegister(Map<String, Object> map);

	/**
	 * 第三方登陆
	 * 
	 * @param memMenber
	 */
	// public int addThirdPartyLogin(Member
	// member);//addThirdPartyLoginQqNumber,addThirdPartyLoginWeiBo,addThirdPartyLoginWeChat
	public int addThirdPartyLoginQqNumber(Member member);

	public int addThirdPartyLoginWeiBo(Member member);

	public int addThirdPartyLoginWeChat(Member member);

	/**
	 * 第三方账号是否已经注册为爱动号会员
	 * 
	 * @param map
	 * @return
	 */
	public int getIfThirdRegisterd(Map<String, Object> map);

	/**
	 * 根据第三方账号获得爱动号
	 * 
	 * @param map
	 * @return
	 */
	public String getThirdByIdongId(Map<String, Object> map);

	/**
	 * 获得头像
	 * 
	 * @param idongId
	 * @return
	 */
	public String getThirdHeadUrl(String idongId);

	/**
	 * 记录登陆信息
	 * 
	 * @param member
	 */
	public void editMemberLoginMsg(Member member);

	/**
	 * 检查用户资料是否完善
	 *
	 * @return
	 */
	public MemberBase getCheckMemberData(@Param("idongId") int idongId);
}
